<?php

namespace app\api\controller;

use think\Controller;
use think\Db;
use think\Log;

class Pay extends Controller
{
    
    public function get_goods_price(){
        $goods_id = (int)input('goods_id',0);
        $user_id = (int)input('user_id',0);
        if($goods_id == 0 || $user_id == 0){
            return 0;
        }

        $arr= db('accounts_info','db_config2')->where('UserID',$user_id)->field('LoginServer')->find();
        $goods = getServerGoods($arr['LoginServer'],$goods_id );
        
        if(empty($goods)){
            return 0;
        }

        return $goods['Price']*100;
    }
}

